7 PRINT "TEXT:": INPUT "";ZZ$: IF ZZ$ = "" THEN CALL 1016: END
8 CALL 770: PRINT ZZ$: CALL 960: GOTO 7
9 GOTO 9000: REM INIT
10 GOSUB 2: GOTO 23010: REM SAVE
200 REM <CTRL-M><CTRL-M><CTRL-M>********.SEARCH.****************<CTRL-J>
210 REM IN:R$=FILE$..A$=SEARCH$..T$=LOCAL
220 FOR L = 1 TO LEN(R$)
230 :: LET T$ = MID$ (R$,L,( LEN(A$)))
240 :: IF T$ = A$ THEN S1 = 1: REM OUT:LOOP.CNTR.SET.TO.SEARCH.RECORD..S1=FOUND.FLAG
250 NEXT : RETURN
300 REM <CTRL-M><CTRL-M><CTRL-M>********.ORDERING.**************<CTRL-J>
310 REM IN:A$(R1,1)=RECORD.DATE
320 FOR I = 1 TO R1
330 :: IF A$(I,1) = "" THEN 360: REM LOOK.FOR.END.OF.DATA
340 :: LET B(I,0) = VAL(A$(I,1)):B(I,1) = I: REM FORM.ARRAYS.OF.DATES.&.REC.NOS
350 NEXT
360 LET N = I -1:M = N
370 LET M = INT(M/2): IF M = 0 THEN 470
380 LET J = 1:K = N -M
390 LET I = J
400 LET L = I +M: IF B(I,0) <B(L,0) THEN 450
410 LET T = B(I,0):B(I,0) = B(L,0):B(L,0) = T
420 LET T1 = B(I,1):B(I,1) = B(L,1):B(L,1) = T1
430 LET I = I -M: IF I <1 THEN 450
440 GOTO 400
450 LET J = J +1: IF J >K THEN 370
460 GOTO 390
470 RETURN : REM OUT:B$(R1,1)=ARRAY.OF.DATE.ORDER
1000 REM <CTRL-M><CTRL-M><CTRL-M>******.MENU.********************<CTRL-J>
1010 REM IN:ND=NEW.DATA.FLAG
1020 TEXT : HOME
1030 VTAB 5
1040 PRINT : PRINT " READ EXISTING FILE 1"
1050 PRINT : PRINT " INPUT NEW DATA 2"
1060 PRINT : PRINT " REVIEW FILE 3"
1070 PRINT : PRINT " EDIT FILE 4"
1080 IF ND THEN FLASH
1090 PRINT : PRINT " SAVE FILE 5"
1100 NORMAL
1110 PRINT : PRINT " PRINT LIST W TOTALS 6"
1120 PRINT : PRINT "SET UP FILES 1ST TIME 7"
1130 PRINT : PRINT " QUIT 8"
1135 PRINT : PRINT " DISPLAY COLUMNS 9"
1140 LET Q = 1: PRINT : PRINT SPC( 15)"WHICH? ";: PRINT Q;: HTAB (23): GET Q$: PRINT Q$: IF Q$ < > CHR$(13) THEN Q = VAL(Q$)
1150 ON Q GOTO 1410,2010,3020,4010,1610,6010,1810,1990,32020
1160 GOTO 1000
1400 REM <CTRL-M><CTRL-M><CTRL-M>********.READ.EXISTING.FILE.****<CTRL-J>
1410 GOSUB 9710: GOTO 1000
1600 REM <CTRL-M><CTRL-M><CTRL-M>********.SAVE.FILE.*************<CTRL-J>
1610 GOSUB 9400: GOTO 1000
1800 REM <CTRL-M><CTRL-M><CTRL-M>********.SET.UP.FILES.1ST.TIME.*<CTRL-J>
1810 PRINT : PRINT : PRINT : PRINT "FILE SET UP WILL DESTROY ANY EXISTING": PRINT "FILE ON THIS DISK. TYPE 'YES' TO": INPUT "CONTINUE. ";A$: IF A$ < >"YES" THEN 1000
1820 GOSUB 9400: GOTO 1000
1980 REM <CTRL-M><CTRL-M><CTRL-M>********.QUIT.******************<CTRL-J>
1990 TEXT : HOME : VTAB 7: PRINT " THIS IS THE": PRINT : PRINT SPC( 10)NA$: PRINT : PRINT SPC( 20)"PROGRAM.": PRINT : PRINT : PRINT : PRINT " BYE FOR NOW, BOB!": PRINT : PRINT : CALL 1016: END
2000 REM <CTRL-M><CTRL-M><CTRL-M>******.INPUT.DATA.**************<CTRL-J>
2010 REM IN:R1=ARRAY.ROWS..A$(R1,C1)=ARRAY
2020 FOR K = 1 TO R1
2030 :: IF A$(K,1) = "" THEN 2050
2040 NEXT K: REM K=NEXT.OPEN
2050 GOSUB 8010: REM INPUT
2060 LET ND = 1: REM NEW.DATA.FLAG
2070 GOTO 1010: REM MENU
2080 REM OUT:ND=NEW.DATA.FLAG..A$(J,1TOC1)=DATA
3000 REM <CTRL-M><CTRL-M><CTRL-M>******.REVIEW.FILE.*************<CTRL-J>